package com.sx.jys.ui.adapter

import android.content.Context
import androidx.recyclerview.widget.RecyclerView
import com.kunminx.binding_recyclerview.adapter.SimpleDataBindingAdapter
import com.sx.jys.R
import com.sx.jys.app.framework.DiffUtilCallbacks
import com.sx.jys.app.net.bean.Code
import com.sx.jys.databinding.ItemHomeListBinding

class HomeListAdapter(context: Context) : SimpleDataBindingAdapter<Code, ItemHomeListBinding>(
    context, R.layout.item_home_list, DiffUtilCallbacks().getItemCallBack()
) {
    override fun onBindItem(
        binding: ItemHomeListBinding,
        item: Code,
        holder: RecyclerView.ViewHolder
    ) {
        binding.data = item
    }
}